#include<stdio.h>
typedef struct hjx
{
    int date;
    struct hjx*zuo;
    struct hjx*you;
}hjx;
hjx* fuzhi(char x)
{
    hjx*newp=(hjx*)malloc(sizeof(hjx));
    newp->date=x;
    newp->you=NULL;
    newp->zuo=NULL;
    return newp;
}
void hou(hjx*root)
{
    if(root==NULL)
    {
        printf("NULL ");
        return;
    }
    hou(root->zuo);
    hou(root->you);
    printf("%c ",root->date);
}

void bianli(hjx*root,int *_size)
{
    if(root==NULL)
    {
        return;
    }
    else
    {
        (*_size)++;
        bianli(root->zuo,_size);
        bianli(root->you,_size);
    }
}
int main()
{
    hjx*A=fuzhi('A');
    hjx*B=fuzhi('B');
    hjx*C=fuzhi('C');
    hjx*D=fuzhi('D');
    hjx*E=fuzhi('E');
    A->zuo=B;
    A->you=C;
    B->zuo=D;
    B->you=E;
//    hou(A);
    int _size=0;
    bianli(A,&_size);
    printf("%d",_size);
}
